package net.llz.controller;


import net.llz.model.UserDO;
import net.llz.service.UserService;
import net.llz.util.JsonData;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author Let_fan
 * @since 2022-10-08
 */
@RestController
@RequestMapping("pub")
public class UserController {

    @Autowired
    private UserService userService;

    @RequestMapping("find_user_info")

    public JsonData findUserInfo(@RequestParam("username") String username){
       UserDO userdata= userService.findAllUserInfoByUsername(username);
        return JsonData.buildSuccess(userdata);
    }

}

